memory_test: list.c list.test.c list.h
	mkdir -p bin/obj/memory_test
	cc -g3 -c -Wall  list.c         -o  bin/obj/memory_test/list.o
	cc -g3 -c -Wall  list.test.c    -o  bin/obj/memory_test/list.test.o
	cc -g3    -Wall  bin/obj/memory_test/list.o bin/obj/memory_test/list.test.o -o bin/list.memory_test
	valgrind  -v --leak-check=full bin/list.memory_test


coverage_test: list.c list.test.c list.h
	mkdir -p bin/obj/coverage_test
	cc  -c -Wall --coverage  list.c         -o  bin/obj/coverage_test/list.o
	cc  -c -Wall --coverage  list.test.c    -o  bin/obj/coverage_test/list.test.o
	cc     -Wall --coverage  bin/obj/coverage_test/list.o bin/obj/coverage_test/list.test.o -o bin/list.coverage_test
	gcov --object-directory bin/obj/coverage_test list.c

clean: 
	rm -f -R bin/obj/*
	rm -f -R bin/list*
 